//
//  BaseInformationTableViewCell.m
//  详细资料
//
//  Created by 李贺 on 2017/1/6.
//  Copyright © 2017年 李贺. All rights reserved.
//

#import "BaseInformationTableViewCell.h"
#import "Masonry.h"
@implementation BaseInformationTableViewCell

// 重写父类的初始化方法,在此方法中添加cell中的子控件
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        // 添加子控件
        [self setupUI];
    }
    return self;
}


- (void)setupUI{
    self.nameLable = [[UILabel alloc] init];
    [self.contentView addSubview:_nameLable];
    
    
    [_nameLable mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.top.bottom.equalTo(self.contentView);
        make.width.offset(self.contentView.bounds.size.width * 0.3);
    }];
    
    self.informationTextField = [[UITextField alloc] init];
    [self.contentView addSubview:_informationTextField];
    
    _informationTextField.textColor = [UIColor darkGrayColor];
    _informationTextField.font = [UIFont systemFontOfSize:15];
    [_informationTextField mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.right.bottom.equalTo(self.contentView);
        make.left.equalTo(_nameLable.mas_right);
    }];
}

@end
